package com.aizhixin.test.errolAlmost.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.aizhixin.test.errolAlmost.dao.SteamAllDAO;
import com.aizhixin.test.errolAlmost.dto.SteamDTO;

@Service
@Transactional
public class steamAllService {
	@Autowired
	private SteamAllDAO errolAllDAO;
	
	
	/**
	 * 输入userId之后调用得到错题集合
	 * @param userId
	 * @return
	 */
	public List<SteamDTO> getErrolAll(Long userId){
		return errolAllDAO.findErrolAllByUserId(userId);
	}
	/**
	 * 输入userId之后调用得到对题集合
	 * @param userid
	 * @return
	 */
	public List<SteamDTO> getRightAll(Long userid){
		return errolAllDAO.findRightAllByUserId(userid);
	}
	/**
	 * 输入userid之后获取所有题的集合
	 * @param userid
	 * @return
	 */
	public List<SteamDTO>  getsteamAll(Long userid){
		return errolAllDAO.findAllByUserId(userid);
	}
	public List<SteamDTO> getSteamByImformation(Long userId, String importImfomation) {
		
		return errolAllDAO.findSteamByImformation(userId,importImfomation);
	}
	
	
}
